<div class="col-sm-12 col-md-12" ng-show="pageView == 0">
    <div class="row">
        <div class="col-sm-12 col-md-12">
            <form class="form-custom clearfix">
                <div class="col-sm-3 col-md-3">
                    <label>需求名称</label>
                    <input class="form-control" type="text" ng-model="params.requName"/>
                </div>
               <div class="col-sm-3 col-md-3">
                    <label>申请日期</label>
                    <div datetimepicker range start="params.applDate" end="params.applDate_"></div>
                </div>
                <div class="col-sm-3 col-md-3">
                    <label>流程类型</label>
                    <select ng-model="params.flowType" select2 ng-options="item.flowType as item.Name for item in flowTypeList"></select>
                </div>
                <div class="col-sm-3 col-md-3">
                    <label>&nbsp;</label>
                    <button class="btn btn-custom" type="button" ng-click="refresh('first',true)">查询</button>
                    <button class="btn btn-custom" type="button" ng-click="toDetail()">新增需求</button>
                    <button class="btn btn-custom" type="button" ng-click="record()">补录</button>
                </div>
            </form>
        </div>
    </div>

            <table class="table table-striped table-bordered table-condensed index-center  table-costom">
                <thead>
                <tr>
                    <th>序号</th>
                    <th>需求编号</th>
                    <th>流程类型</th>
                    <th>需求名称</th>
                    <th>需求类型</th>
                    <th>申请人部门</th>
                    <th>申请人</th>
                    <th>申请时间</th>
                    <th>状态</th>
                    <th>操作</th>
                </tr>
                </thead>
                <tbody>
                <tr class="rowlink" ng-repeat="item in limitArr">
                    <td>{{$index+1}}</td>
                    <td>{{item.requCode}}</td>
                    <td>{{item.flowType | DM_flow_type}}</td>
                    <td>{{item.requName}}</td>
                    <td>{{item.requType | DM_requ_type}}</td>
                    <td>{{item.applDept}}</td>
                    <td>{{item.applPer}}</td>
                    <td>{{item.applDate | date:'yyyy-MM-dd'}}</td>
                    <td>{{item.approState | DM_appro_state}}</td>
                    
                    <td>
                        <a href="javascript:"  data-toggle="modal" data-target="#seeDialog" ng-click="toSeeDetail(copy(item))">查看</a>
                        <a href="javascript:"  data-toggle="modal" data-target="#stepDialog" ng-click="toFollow(copy(item))">跟踪</a>
                        <a href="javascript:"  data-toggle="modal" data-target="#edit" ng-click="toDetail(copy(item))" ng-show="item.approState==1" upload-refresh="true">修改</a>
                        <a href="javascript:"  data-toggle="modal" data-target="#remove" ng-click="toDelete(copy(item))" ng-show="item.approState==1">删除</a>
                        <a href="javascript:"  data-toggle="modal" data-target="#send" ng-click="toGoCheck(copy(item))" ng-show="item.approState==1">提交审核</a>
                        <a href="javascript:"  data-toggle="modal" data-target="#terminate" ng-click="toTerminateTask(copy(item))" ng-show="item.approState==1">终止</a>
                    </td>
                </tr>
                </tbody>
            </table>

    <div data-remote-paging="pager" 
				data-refresh="refresh" 
				data-current="current" 
				data-total="total" 
				data-data="limitArr"
				data-limit="limit"
				data-params="params"
			></div>

</div>


<!-- 新增/修改对话框 -->
<div class="col-sm-12 col-md-12" ng-if="pageView == 1">
<form class="form-horizontal" name="DM" novalidate="novalidate" auto-file-upload ng-submit="isCreate ? create(demand) : modify(demand)"> 
	<div class="row">
		<div class="col-sm-12 col-md-12">
		    <div class="form-group">
		        <label class="col-lg-3 control-label">流程类型</label>
	            <div class="col-lg-8">	
		            <select class="form-control" ng-model="demand.flowType" name="flowType" required ng-disabled="demand.id" ng-options="item.key as item.name for item in reqList">
		            </select>
	            </div>
	            <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'inside'">
		        <label class="col-lg-3 control-label">技术联系人</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="技术联系人" ng-model="demand._techContact.userName" id="techContacts" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'techContact' ,'JSLXR')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label"> 省内专门联系人</label>
		        <div class="col-lg-8">
		            <div class="input-group">     
		            	<input type="text" placeholder="省内专门联系人" ng-model="demand._provContacts.userName" id="provContacts" class="form-control" readonly="readonly"
						required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'provContacts' ,'JSLXR')">选择</button>
       					 </div>
               		</div>
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label">集团技术联系人</label>
		        <div class="col-lg-8">
		            <div class="input-group">     
		            	<input type="text" placeholder="集团技术联系人" ng-model="demand._groupTechContacts.userName" id="groupTechContacts" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'groupTechContacts' ,'99')">选择</button>
       					 </div>
               		</div>
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求编号</label>
	            <div class="col-lg-8">	
	            	<input type="text" placeholder="需求编号" ng-model="demand.requCode" readonly="readonly" class="form-control">
	            	<!--   ng-value="reqTypeCd[demand.flowType]"   -->
	            </div>
	            <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求名称</label>
		        <div class="col-lg-8">
		            <input type="text" placeholder="需求名称" ng-model="demand.requName"  class="form-control"
		            maxlength="10"
		            required
                    valid-tip="{required:'需求名称非空'}"
                    valid-pos="bottom"
		            >
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求类型</label>
		        <div class="col-lg-8">
		            <select class="form-control" ng-model="demand.requType" ng-disabled="demand.id">
		                <option value="1">数据提取</option>
		                <option value="2">专题分析</option>
		                <option value="3">统计报表</option>
		            </select>
		        </div>
		        <span style="color: red">*</span>
		    </div>
	        <div class="form-group" ng-if="demand.requType == 1">
	            <label class="col-lg-3 control-label">项目申请单位</label>
	            <div class="col-lg-8">
	                <div class="input-group">      
	                	<input type="text" placeholder="项目申请单位" ng-model="demand.objApplyOrg" id="objApplyOrg" class="form-control" readonly="readonly"
	                	required 
	                    valid-tip="{required:'项目申请单位非空'}"
	                    valid-pos="bottom"
	                	>                      
	                	<div class="input-group-btn">                                
	                		<button type="button" class="btn btn-default" data-toggle="modal" ng-click="openSearch('tree' , 'objApplyOrg' ,'name')" data-target="#select">选择</button>
	                	</div>                      
	                </div>
	            </div>
	            <span style="color: red">*</span>
	        </div>
	        <div class="form-group">
	            <label class="col-lg-3 control-label">申请人</label>
	            <div class="col-lg-8" ng-if="!demand.id">
	                <input type="text" placeholder="申请人" ng-model="demand.applPer" id="applPer" class="form-control" readonly="readonly">
	            </div>
	            <div class="col-lg-8" ng-if="demand.id">
	                <input type="text" placeholder="申请人" ng-model="demand.applPer_" id="applPer" class="form-control" readonly="readonly">
	            </div>
	            <span style="color: red">*</span>
	        </div>
		    <div ng-if="demand.requType == 2 || demand.requType == 3">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">申请人单位</label>
		            <div class="col-lg-8">
		                <div class="input-group">      
		                	<input type="text" placeholder="申请人单位" ng-model="demand.applOrg" id="applOrg" class="form-control" readonly="readonly"
		                	required 
		                    valid-tip="{required:'申请人单位非空'}"
		                    valid-pos="bottom"
		                	>                      
		                	<div class="input-group-btn">                                
		                		<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('tree' , 'applOrg' ,'name')">选择</button>
		                	</div>
		                </div>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">申请人部门</label>
		            <div class="col-lg-8">
		                <input type="text" placeholder="申请人部门" ng-model="demand.applDept" id="applDept" class="form-control"
		                maxlength='20'
	                	required 
	                    valid-tip="{required:'申请人部门非空'}"
	                    valid-pos="bottom"
		                >
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		    <div ng-if="demand.requType == 1">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">安全级别</label>
		            <div class="col-lg-8">
		                <select class="form-control" ng-model="demand.securityLev" required>
		                    <option value="1">公开</option>
		                    <option value="2">绝密</option>
		                </select>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">紧急程度</label>
		            <div class="col-lg-8">
		                <select class="form-control" ng-model="demand.emergencyLev" required>
		                    <option value="1">一般</option>
		                    <option value="2">紧急</option>
		                </select>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		    
		    <div ng-if="demand.requType == 2 || demand.requType == 3">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">数据抽取方式</label>
		            <div class="col-lg-8" >
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="1"> 全量</label>
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="2"> 增量</label>
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="3"> 抽样</label>
		                <span style="color: red">*</span>
		            </div>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">交付日期 </label>
		            <div class="col-lg-8">
		                <div data-datetimepicker="demand.analCyclStart" ng-model="demand.analCyclStart" start-date="today"
		                 required
	                     valid-tip="{required:'交付日期非空'}"
	                     valid-pos="bottom"
		                ></div>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求描述</label>
		        <div class="col-lg-8" >
		            <textarea class="form-control" rows="3"  ng-model="demand.requDesc"
		            maxlength='150'
	                 required
                     valid-tip="{required:'需求描述非空'}"
                     valid-pos="bottom"
		            ></textarea>
		            <span style="color: red" class="help-block">(限200字)</span>
		        </div>
		        <span style="color: red">*</span>
		    </div>
	         <div class="form-group">
	             <label class="col-lg-3 control-label">附件列表</label>
	             <div class="col-lg-8">
	             	<ul>
	             		<li ng-repeat="item in fileList">
	             			<a href="javascript:" ng-click="download(item)">{{item.fileName}}</a> 
	             			<a href="javascript:" data-toggle="modal" data-target="#removeAnnex" ng-click="toDeleteAnnex(item.fileId, demand)" >删除</a>
	             		</li>
	             	</ul>
	             </div>
	         </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求文档</label>
		        <div class="col-lg-8">
 					<div uploader 
 						multiple 
 						ng-model="demand.fileResponseList" 
 						name="manyFiles" 
 						server="upload.shtml" 
 						files="files" 
 						extensions="doc,docx,xls,xlsx,ppt,pptx,csv,txt"
 						file-queued-error="fn($file,$type,$ext)"
 					></div>
		        </div>
		    </div>

		</div>
		<div class="row text-center">
			<button type="submit" ng-if="!demand.id" class="btn btn-primary" ng-click="isCreate=true;isUpdate=false" ng-disabled="DM.$invalid">保存</button><!--  || !api.isComplete -->
			<button type="submit" ng-if="demand.id" class="btn btn-primary" ng-click="isCreate=false;isUpdate=true;"  ng-disabled="DM.$invalid">修改</button>
			<button type="button" class="btn btn-default" ng-click="toPageView(0)">取消</button>
		</div>
</div>
</form>
</div>

<!-- 删除附件对话框 -->
<div class="modal fade" id="removeAnnex" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">删除附件</h4>
            </div>
            <div class="modal-body">
                确认要删除此附件么？
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-danger" data-dismiss="modal" ng-click="delAttach()">确认删除</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    <!-- /.modal-dialog -->
</div><!-- /.modal -->

<!-- 补录对话框 -->
<div class="col-sm-12 col-md-12" ng-if="pageView == 2">
<form class="form-horizontal" name="DM" novalidate="novalidate" auto-file-upload ng-submit="createIt(demand)">
	<div class="row">
		<div class="col-sm-12 col-md-12 form-horizontal">
		    <div class="form-group">
		        <label class="col-lg-3 control-label">流程类型</label>
	            <div class="col-lg-8">	
		            <select class="form-control" ng-model="demand.flowType" name="flowType" required ng-disabled="demand.id" ng-options="item.key as item.name for item in reqList">
		            </select>
	            </div>
	            <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'inside'">
		        <label class="col-lg-3 control-label">业务领导审批人</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="业务领导审批人" ng-model="demand._busBoss.userName" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'busBoss','YWLDSP')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'inside' || demand.flowType == 'tech'">
		        <label class="col-lg-3 control-label">技术领导审批人</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="技术领导审批人" ng-model="demand._techBoss.userName" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'techBoss' ,'JSLDSP')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label" >省内领导</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="省内领导" ng-model="demand._proBoss.userName" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'proBoss','JSLDSP')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label">集团领导</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="集团领导" ng-model="demand._groupBoss.userName" id="techContacts" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'groupBoss' ,'99')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'inside'">
		        <label class="col-lg-3 control-label">技术联系人</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="技术联系人" ng-model="demand._techContact.userName" id="techContacts" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'techContact' ,'JSLXR')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label"> 省内专门联系人</label>
		        <div class="col-lg-8">
		            <div class="input-group">     
		            	<input type="text" placeholder="省内专门联系人" ng-model="demand._provContacts.userName" id="provContacts" class="form-control" readonly="readonly"
						required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'provContacts','JSLXR')">选择</button>
       					 </div>
               		</div>
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label">集团技术联系人</label>
		        <div class="col-lg-8">
		            <div class="input-group">     
		            	<input type="text" placeholder="集团技术联系人" ng-model="demand._groupTechContacts.userName" id="groupTechContacts" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'groupTechContacts' ,'99')">选择</button>
       					 </div>
               		</div>
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'inside' || demand.flowType == 'tech'">
		        <label class="col-lg-3 control-label">技术需求确认人</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="技术需求确认人" ng-model="demand._techConfirm.userName" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'techConfirm','JSXUQJ')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group" ng-if="demand.flowType == 'outside'">
		        <label class="col-lg-3 control-label">集团技术操作员</label>
		        <div class="col-lg-8">
 					<div class="input-group">     
		            	<input type="text" placeholder="集团技术操作员" ng-model="demand._techConfirm.userName" class="form-control" readonly="readonly"
		            	required
		            	>
						 <div class="input-group-btn">   
          				  	<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('0' , 'techConfirm','99')">选择</button>
       					 </div>
               		 </div>
                </div> 
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求编号</label>
	            <div class="col-lg-8">	
	            	<input type="text" placeholder="需求编号" ng-model="demand.requCode" readonly="readonly" class="form-control">
	            	<!--   ng-value="reqTypeCd[demand.flowType]"   -->
	            </div>
	            <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求名称</label>
		        <div class="col-lg-8">
		            <input type="text" placeholder="需求名称" ng-model="demand.requName"  class="form-control"
		            maxlength="10"
		            required
                    valid-tip="{required:'需求名称非空'}"
                    valid-pos="bottom"
		            >
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求类型</label>
		        <div class="col-lg-8">
		            <select class="form-control" ng-model="demand.requType" ng-disabled="demand.id">
		                <option value="1">数据提取</option>
		                <option value="2">专题分析</option>
		                <option value="3">统计报表</option>
		            </select>
		        </div>
		        <span style="color: red">*</span>
		    </div>
	        <div class="form-group" ng-if="demand.requType == 1">
	            <label class="col-lg-3 control-label">项目申请单位</label>
	            <div class="col-lg-8">
	                <div class="input-group">      
	                	<input type="text" placeholder="项目申请单位" ng-model="demand.objApplyOrg" id="objApplyOrg" class="form-control" readonly="readonly"
	                	required 
	                    valid-tip="{required:'项目申请单位非空'}"
	                    valid-pos="bottom"
	                	>                      
	                	<div class="input-group-btn">                                
	                		<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('tree' , 'objApplyOrg' ,'name')">选择</button>
	                	</div>                      
	                </div>
	            </div>
	            <span style="color: red">*</span>
	        </div>
	        <div class="form-group">
	            <label class="col-lg-3 control-label">申请人</label>
	            <div class="col-lg-8" ng-if="!demand.id">
	                <input type="text" placeholder="申请人" ng-model="demand.applPer" id="applPer" class="form-control" readonly="readonly">
	            </div>
	            <span style="color: red">*</span>
	        </div>
		    <div ng-if="demand.requType == 2 || demand.requType == 3">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">申请人单位</label>
		            <div class="col-lg-8">
		                <div class="input-group">      
		                	<input type="text" placeholder="申请人单位" ng-model="demand.applOrg" id="applOrg" class="form-control" readonly="readonly"
		                	required 
		                    valid-tip="{required:'申请人单位非空'}"
		                    valid-pos="bottom"
		                	>                      
		                	<div class="input-group-btn">                                
		                		<button type="button" class="btn btn-default" data-toggle="modal" data-target="#select" ng-click="openSearch('tree' , 'applOrg' ,'name')">选择</button>
		                	</div>
		                </div>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">申请人部门</label>
		            <div class="col-lg-8">
		                <input type="text" placeholder="申请人部门" ng-model="demand.applDept" id="applDept" class="form-control"
		                maxlength='20'
	                	required 
	                    valid-tip="{required:'申请人部门非空'}"
	                    valid-pos="bottom"
		                >
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		    <div ng-if="demand.requType == 1">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">安全级别</label>
		            <div class="col-lg-8">
		                <select class="form-control" ng-model="demand.securityLev" required>
		                    <option value="1">公开</option>
		                    <option value="2">绝密</option>
		                </select>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">紧急程度</label>
		            <div class="col-lg-8">
		                <select class="form-control" ng-model="demand.emergencyLev" required>
		                    <option value="1">一般</option>
		                    <option value="2">紧急</option>
		                </select>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		    
		    <div ng-if="demand.requType == 2 || demand.requType == 3">
		        <div class="form-group">
		            <label class="col-lg-3 control-label">数据抽取方式</label>
		            <div class="col-lg-8" >
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="1"> 全量</label>
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="2"> 增量</label>
		                <label class="radio-inline"><input type="radio" ng-model="demand.dataExtrType" name="class4" required value="3"> 抽样</label>
		                <span style="color: red">*</span>
		            </div>
		        </div>
		        <div class="form-group">
		            <label class="col-lg-3 control-label">交付日期 </label>
		            <div class="col-lg-8">
		                <div data-datetimepicker="demand.analCyclStart" ng-model="demand.analCyclStart" start-date="today"
		                 required
	                     valid-tip="{required:'交付日期非空'}"
	                     valid-pos="bottom"
		                ></div>
		            </div>
		            <span style="color: red">*</span>
		        </div>
		    </div>
		
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求描述</label>
		        <div class="col-lg-8" >
		            <textarea class="form-control" rows="3"  ng-model="demand.requDesc"
		             maxlength='150'
	                 required
                     valid-tip="{required:'需求描述非空'}"
                     valid-pos="bottom"
		            ></textarea>
		            <span style="color: red" class="help-block">(限200字)</span>
		        </div>
		        <span style="color: red">*</span>
		    </div>
		    <div class="form-group">
		        <label class="col-lg-3 control-label">需求文档</label>
		        <div class="col-lg-8">
 					<div uploader 
 						multiple 
 						ng-model="demand.fileResponseList" 
 						name="manyFiles" 
 						server="upload.shtml" 
 						files="files" 
 						extensions="doc,docx,xls,xlsx,ppt,pptx,csv,txt"
 						file-queued-error="fn($file,$type,$ext)"
 					></div>
		        </div>
		    </div>
		</div>
		<div class="row text-center">
			<button type="submit" class="btn btn-primary" ng-disabled="DM.$invalid">保存</button><!--  || !api.isComplete -->
			<button type="button" class="btn btn-default" ng-click="toPageView(0)">取消</button>
		</div>
</div>
</form>
</div>

<!-- 终止对话框 -->
<div class="modal fade" id="terminate" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">终止流程</h4>
            </div>
            <div class="modal-body">
                确认要终止此流程么？
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-danger" data-dismiss="modal" ng-click=doTerminateTask(demand)>确认终止</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    <!-- /.modal-dialog -->
</div><!-- /.modal -->


<!-- 删除对话框 -->
<div class="modal fade" id="remove" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">删除数据</h4>
            </div>
            <div class="modal-body">
                确认要删除此数据么？
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-danger" data-dismiss="modal" ng-click=remove(demand)>确认删除</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    <!-- /.modal-dialog -->
</div><!-- /.modal -->

<!-- 查看对话框 -->
<div class="modal fade" id="seeDialog" tabindex="-1" role="dialog" aria-hidden="true">
<form class="form-horizontal" novalidate="novalidate">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">查看</h4>
            </div>
            <div class="modal-body">
                <div class="row">
                    <div class="col-sm-12 col-md-12">
                            <div class="form-group">
                                <label class="col-lg-2 control-label">流程类型</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.flowType | DM_flow_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">提出人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applPer_}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.flowType == 'inside'">
                                <label class="col-lg-2 control-label">技术联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.techContacts_}}</p>
                                </div>
                            </div>
			    			<div class="form-group" ng-if="see_demand.flowType == 'outside'">
                                <label class="col-lg-2 control-label">省内专门联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.provContacts_}}</p>
                                </div>
                            </div>
			   				 <div class="form-group" ng-if="see_demand.flowType == 'outside'">
                                <label class="col-lg-2 control-label">集团技术联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.groupTechContacts_}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求编号</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requCode}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求名称</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requName}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">项目申请单位</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.objApplyOrg}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '2' || see_demand.requType == '3'">
                                <label class="col-lg-2 control-label">提出部门</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applDept}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求类型</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requType | DM_requ_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">申请时间</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applDate | date:'yyyy-MM-dd'}}</p>
                                </div>
                            </div>
                            <div class="form-group"  ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">安全级别</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.securityLev | DM_security_lev}}</p>
                                </div>
                            </div>
                            <div class="form-group"  ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">紧急程度</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.emergencyLev | DM_emergency_lev}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '2' || see_demand.requType == '3'">
                                <label class="col-lg-2 control-label">数据抽取方式</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.dataExtrType | DM_data_extr_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求描述</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requDesc}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">附件列表</label>
                                <div class="col-lg-10">
                                	<ul>
                                		<li ng-repeat="item in fileList"><a href="javascript:" ng-click="download(item)">{{item.fileName}}</a></li>
                                	</ul>
                                </div>
                            </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    <!-- /.modal-dialog -->
    </form>
</div><!-- /.modal -->


<!-- 提交审核对话框 -->
<div class="modal fade" id="send" tabindex="-1" role="dialog" aria-hidden="true">
<form class="form-horizontal" name="SH" novalidate="novalidate">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">提交审核</h4>
            </div>
            <div class="modal-body">
                <div class="row">
                    <div class="col-sm-12 col-md-12">
							<div class="form-group">
                                <label class="col-lg-2 control-label">流程类型</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.flowType | DM_flow_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">提出人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applPer_}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.flowType == 'inside'">
                                <label class="col-lg-2 control-label">技术联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.techContacts_}}</p>
                                </div>
                            </div>
			    			<div class="form-group" ng-if="see_demand.flowType == 'outside'">
                                <label class="col-lg-2 control-label">省内专门联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.provContacts_}}</p>
                                </div>
                            </div>
			   				 <div class="form-group" ng-if="see_demand.flowType == 'outside'">
                                <label class="col-lg-2 control-label">集团技术联系人</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.groupTechContacts_}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求编号</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requCode}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求名称</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requName}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">项目申请单位</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.objApplyOrg}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '2' || see_demand.requType == '3'">
                                <label class="col-lg-2 control-label">提出部门</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applDept}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求类型</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requType | DM_requ_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">申请时间</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.applDate | date:'yyyy-MM-dd'}}</p>
                                </div>
                            </div>
                            <div class="form-group"  ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">安全级别</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.securityLev | DM_security_lev}}</p>
                                </div>
                            </div>
                            <div class="form-group"  ng-if="see_demand.requType == '1'">
                                <label class="col-lg-2 control-label">紧急程度</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.emergencyLev | DM_emergency_lev}}</p>
                                </div>
                            </div>
                            <div class="form-group" ng-if="see_demand.requType == '2' || see_demand.requType == '3'">
                                <label class="col-lg-2 control-label">数据抽取方式</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.dataExtrType | DM_data_extr_type}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">需求描述</label>

                                <div class="col-lg-10">
                                    <p class="form-control-static">{{see_demand.requDesc}}</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">附件列表</label>

                                <div class="col-lg-10">
                                	<ul>
                                		<li ng-repeat="item in fileList"><a href="javascript:" ng-click="download(item)">{{item.fileName}}</a></li>
                                	</ul>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">待执行用户</label>

                                <div class="col-lg-10">
                                    <select select2 ng-model="see_demand.userName" ng-options="item.logName as item.userName for item in asUserList" 
                                    required
                                    ></select>
                                </div>
                            </div>
                            <div class="form-group">
                                <label class="col-lg-2 control-label">备注</label>

                                <div class="col-lg-10">
                                    <textarea class="form-control" rows="3" ng-model="see_demand.remarks" maxlength='100'></textarea>
                                </div>
                            </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-primary" data-dismiss="modal" ng-click=toSubmit(see_demand) ng-disabled="SH.$invalid">提交</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    </form>
    <!-- /.modal-dialog -->
</div><!-- /.modal -->


<!-- 选择对话框 -->
<div class="modal fade" id="select" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog" style="width: 800px;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                <h4 class="modal-title">请选择</h4>
            </div>
            <div class="modal-body">
                <div class="row" ng-if="searchType == 0"><!-- 用来查询项目申请单位的条件 -->
                    <div class="col-sm-4 col-md-4">
                    	<label>联系人姓名</label>
                    	<input type="text" class="form-control" ng-model="searchParams.userName"/>
                    </div>
                    <div class="col-sm-4 col-md-4">
                    	<label>&nbsp;</label>
                    	<button class="btn btn-info" ng-click="searchData(searchParams)">查询</button>
                    	<label>&nbsp;</label>
                    </div>
                </div>
                
                <table class="table table-striped table-bordered table-condensed index-center  table-costom" ng-if="searchType != 'tree'">
	                <thead>
		                <tr>
		                    <th>序号</th>
		                    <th>姓名</th>
		                    <th>单位</th>
		                    <th>电话</th>
		                    <th>邮箱</th>
		                    <th>操作</th>
		                </tr>
	                </thead>
                	<tbody>
	                	<tr class="rowlink" ng-repeat="item in searchList">
	                		<td>{{$index + 1}}</td>
	                		<td>{{item.userName}}</td>
	                		<td>{{item.orgName}}</td>
	                		<td>{{item.phone}}</td>
	                		<td>{{item.email}}</td>
	                		<td><a href="javascript:" data-dismiss="modal" ng-click="selected(item)">选择</a></td>
	                	</tr>
                	</tbody>
                </table>
            	<div ng-if="searchType == 'tree'">
            		<ul class="ztree" data-ztree="zTreeApi" data-setting="treeSetting" data-data="treeData"></ul>
            	</div>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
    <!-- /.modal-dialog -->
</div><!-- /.modal -->

<a id="downlink" target="_blank"></a>


<div ng-include="'templates/technologicalProcess/steps-extends.html'"></div>
<div ng-include="'templates/technologicalProcess/details-extends.html'"></div>